package com.example.flieswar.controller;

import java.awt.Color;
import java.awt.Component;
import javax.swing.JFrame;

/**
 * 主类
 */
public class GameFrame extends JFrame {

    public static final int WIDTH = 512 ;//窗口的宽
    public static final int HEIGHT = 768 ;//窗口的高

    public static void main(String[] args) {
        GameFrame frame = new GameFrame();
        GamePanel panel = new GamePanel(frame);
        panel.startGameAction();
        frame.add(panel);
        frame.setVisible(true);
    }

    public GameFrame() {
        this.setTitle("全民飞机大战");
        this.setSize(512, 768);
        this.setBackground(Color.cyan);
        this.setLocationRelativeTo((Component)null);
        this.setResizable(false);
        this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    }
}
